<?xml version="1.0" encoding="UTF-8"?>
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
   xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
   xmlns:f="http://xmlns.jcp.org/jsf/core"
   xmlns:h="http://xmlns.jcp.org/jsf/html"
   xmlns:p="http://primefaces.org/ui"
   xmlns:c="http://xmlns.jcp.org/jsp/jstl/core"
   template="/WEB-INF/templates/default.xhtml"
   >
   
   	<f:metadata>
	   	<f:viewParam name="bulletinId" value="#{bulletinHome3.id}"></f:viewParam>	  
	   	<f:viewParam name="moduleName" value="公告查看"></f:viewParam>	
   	</f:metadata>
   	<ui:define name="head">
   		<style type="text/css">
   			.removeButton {
   				float: right;
   				margin-right: 20px;
   			}
   			.limitUnit{
   				margin-top:5px;
   			}
   			h2{
   				text-align:center
   			}
   			.rowStyle{
	   			text-align: center;
	   			font-size:16px
   			}
   		</style>
   	</ui:define>
   	<ui:define name="content">
   
		<h:form id="viewForm"  > 
		
			<p:panel id="appliedSuppliers" header="已报名的中介" style="margin-bottom:10px;">
				<h2>共<font color="red">#{bulletinHome3.instance.verifiedTrades.size()}</font>家</h2>
				<ul>
					<p:repeat var="_trade" value="#{bulletinHome3.instance.verifiedTrades}"  varStatus="_status">
						<li>
							<h:outputText value="#{_status.index+1}、#{_trade.supplier.cnname}" />
							#{_trade.applyTime}
						</li>
					</p:repeat>
				</ul>
			</p:panel>
			<p:panel id="applyingSuppliers" header="收到邀请的的中介" style="margin-bottom:10px;">
				<h2>共<font color="red">#{bulletinHome3.instance.trades.size()}</font>家</h2>
				<ul>
					<p:repeat var="_trade" value="#{bulletinHome3.instance.trades}" varStatus="_status">
						<li>
							<h:outputText value="#{_status.index+1}、#{_trade.supplier.cnname}" />
						</li>
					</p:repeat>
				</ul>
			</p:panel>    
			
			<p:panel id="notAppliedSuppliers" header="未报名的的中介" style="margin-bottom:10px;">
				<h2>共<font color="red">#{bulletinHome3.instance.getNotVerifiedTrades().size()}</font>家</h2>
				<ul>
					<p:repeat var="_trade" value="#{bulletinHome3.instance.getNotVerifiedTrades()}" varStatus="_status">
						<li>
							<h:outputText value="#{_status.index+1}、#{_trade.supplier.cnname}" />
						</li>
					</p:repeat>
				</ul>
			</p:panel> 
			    
			<p:panel id="panel" header="公告信息" style="margin-bottom:10px;">
		        <ui:include src="../template/include/bulletinInfo.xhtml" />
			</p:panel>
			
			<ui:include src="../template/include/bulletinReqInfo.xhtml" />
			<p:panel header="相关附件">	
				 	<ui:include src="/WEB-INF/templates/include/bulletinAttachments.xhtml" />
			</p:panel>
			<p:panel
				id="selecteSupplier"
				header="已选取的中介"
				rendered="#{not empty bulletinHome3.instance.successTrade}"
				style="margin-bottom:10px;"
			>
				<p:outputLabel
					for="supplier"
					value="中介名称："
					style="margin:5px 10px"
				></p:outputLabel>
				<h:outputText
					id="supplier"
					value="#{bulletinHome3.instance.successTrade.supplier.cnname}"
				/>
			</p:panel>
			<p:panel
				id="backupSuppliers"
				header="备选中介"
				rendered="#{not empty bulletinHome3.instance.backupTrades}"
				style="margin-bottom:10px;"
			>
				<p:outputLabel
					for="backupSupplier"
					value="备选中介名称："
					style="margin:5px 10px"
				></p:outputLabel>
				<h:outputText
					id="backupSupplier"
					value="#{bulletinHome3.instance.getBackUpSupplierNames()}"
				/>
			</p:panel>		
			<p:button outcome="BulletinList.xhtml" value="完成"></p:button>	
		</h:form>		
   	</ui:define>
</ui:composition>
